﻿using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using PortaCapena.OdooJsonRpcClient.Attributes;
using PortaCapena.OdooJsonRpcClient.Converters;
using PortaCapena.OdooJsonRpcClient.Models;
using System;
using System.ComponentModel;
using System.Runtime.Serialization;

namespace OdooRpcClient.Model.Hr
{
    [OdooTableName("hr.department")]
    [JsonConverter(typeof(OdooModelConverter))]
    public class HrDepartmentOdooModel : IOdooModel
    {

        /// <summary>
        /// Name
        /// Char
        /// required
        /// <summary>
        [JsonProperty("name")]
        [Description("Name")]
        public string Name { get; set; }

        /// <summary>
        /// CompleteName
        /// Char
        /// <summary>
        [JsonProperty("complete_name")]
        [Description("CompleteName")]
        public string CompleteName { get; set; }

        /// <summary>
        /// Active
        /// Boolean
        /// <summary>
        [JsonProperty("active")]
        [Description("Active")]
        public bool? Active { get; set; }

        /// <summary>
        /// CompanyId
        /// Many2one
        /// res.company
        /// <summary>
        [JsonProperty("company_id")]
        [Description("CompanyId")]
        public long? CompanyId { get; set; }

        /// <summary>
        /// ParentId
        /// Many2one
        /// hr.department
        /// <summary>
        [JsonProperty("parent_id")]
        [Description("ParentId")]
        public long? ParentId { get; set; }

        /// <summary>
        /// ChildIds
        /// One2many
        /// hr.department
        /// parent_id
        /// <summary>
        [JsonProperty("child_ids")]
        [Description("ChildIds")]
        public long[] ChildIds { get; set; }

        /// <summary>
        /// ManagerId
        /// Many2one
        /// hr.employee
        /// <summary>
        [JsonProperty("manager_id")]
        [Description("ManagerId")]
        public long? ManagerId { get; set; }

        /// <summary>
        /// MemberIds
        /// One2many
        /// hr.employee
        /// department_id
        /// <summary>
        [JsonProperty("member_ids")]
        [Description("MemberIds")]
        public long[] MemberIds { get; set; }

        /// <summary>
        /// JobsIds
        /// One2many
        /// hr.job
        /// department_id
        /// <summary>
        [JsonProperty("jobs_ids")]
        [Description("JobsIds")]
        public long[] JobsIds { get; set; }

        /// <summary>
        /// Note
        /// Text
        /// <summary>
        [JsonProperty("note")]
        [Description("Note")]
        public string Note { get; set; }

        /// <summary>
        /// Color
        /// Integer
        /// <summary>
        [JsonProperty("color")]
        [Description("Color")]
        public int? Color { get; set; }

        /// <summary>
        /// AbsenceOfToday
        /// Integer
        /// <summary>
        [JsonProperty("absence_of_today")]
        [Description("AbsenceOfToday")]
        public int? AbsenceOfToday { get; set; }

        /// <summary>
        /// LeaveToApproveCount
        /// Integer
        /// <summary>
        [JsonProperty("leave_to_approve_count")]
        [Description("LeaveToApproveCount")]
        public int? LeaveToApproveCount { get; set; }

        /// <summary>
        /// AllocationToApproveCount
        /// Integer
        /// <summary>
        [JsonProperty("allocation_to_approve_count")]
        [Description("AllocationToApproveCount")]
        public int? AllocationToApproveCount { get; set; }

        /// <summary>
        /// TotalEmployee
        /// Integer
        /// <summary>
        [JsonProperty("total_employee")]
        [Description("TotalEmployee")]
        public int? TotalEmployee { get; set; }

        /// <summary>
        /// NewApplicantCount
        /// Integer
        /// <summary>
        [JsonProperty("new_applicant_count")]
        [Description("NewApplicantCount")]
        public int? NewApplicantCount { get; set; }

        /// <summary>
        /// NewHiredEmployee
        /// Integer
        /// <summary>
        [JsonProperty("new_hired_employee")]
        [Description("NewHiredEmployee")]
        public int? NewHiredEmployee { get; set; }

        /// <summary>
        /// ExpectedEmployee
        /// Integer
        /// <summary>
        [JsonProperty("expected_employee")]
        [Description("ExpectedEmployee")]
        public int? ExpectedEmployee { get; set; }

        /// <summary>
        /// ExpenseSheetsToApproveCount
        /// Integer
        /// <summary>
        [JsonProperty("expense_sheets_to_approve_count")]
        [Description("ExpenseSheetsToApproveCount")]
        public int? ExpenseSheetsToApproveCount { get; set; }

        /// <summary>
        /// MessageIsFollower
        /// Boolean
        /// <summary>
        [JsonProperty("message_is_follower")]
        [Description("MessageIsFollower")]
        public bool? MessageIsFollower { get; set; }

        /// <summary>
        /// MessageFollowerIds
        /// One2many
        /// mail.followers
        /// res_id
        /// <summary>
        [JsonProperty("message_follower_ids")]
        [Description("MessageFollowerIds")]
        public long[] MessageFollowerIds { get; set; }

        /// <summary>
        /// MessagePartnerIds
        /// Many2many
        /// res.partner
        /// <summary>
        [JsonProperty("message_partner_ids")]
        [Description("MessagePartnerIds")]
        public long[] MessagePartnerIds { get; set; }

        /// <summary>
        /// MessageChannelIds
        /// Many2many
        /// mail.channel
        /// <summary>
        [JsonProperty("message_channel_ids")]
        [Description("MessageChannelIds")]
        public long[] MessageChannelIds { get; set; }

        /// <summary>
        /// MessageIds
        /// One2many
        /// mail.message
        /// res_id
        /// <summary>
        [JsonProperty("message_ids")]
        [Description("MessageIds")]
        public long[] MessageIds { get; set; }

        /// <summary>
        /// MessageUnread
        /// Boolean
        /// If checked, new messages require your attention.
        /// <summary>
        [JsonProperty("message_unread")]
        [Description("MessageUnread")]
        public bool? MessageUnread { get; set; }

        /// <summary>
        /// MessageUnreadCounter
        /// Integer
        /// Number of unread messages
        /// <summary>
        [JsonProperty("message_unread_counter")]
        [Description("MessageUnreadCounter")]
        public int? MessageUnreadCounter { get; set; }

        /// <summary>
        /// MessageNeedaction
        /// Boolean
        /// If checked, new messages require your attention.
        /// <summary>
        [JsonProperty("message_needaction")]
        [Description("MessageNeedaction")]
        public bool? MessageNeedaction { get; set; }

        /// <summary>
        /// MessageNeedactionCounter
        /// Integer
        /// Number of messages which requires an action
        /// <summary>
        [JsonProperty("message_needaction_counter")]
        [Description("MessageNeedactionCounter")]
        public int? MessageNeedactionCounter { get; set; }

        /// <summary>
        /// MessageHasError
        /// Boolean
        /// If checked, some messages have a delivery error.
        /// <summary>
        [JsonProperty("message_has_error")]
        [Description("MessageHasError")]
        public bool? MessageHasError { get; set; }

        /// <summary>
        /// MessageHasErrorCounter
        /// Integer
        /// Number of messages with delivery error
        /// <summary>
        [JsonProperty("message_has_error_counter")]
        [Description("MessageHasErrorCounter")]
        public int? MessageHasErrorCounter { get; set; }

        /// <summary>
        /// MessageAttachmentCount
        /// Integer
        /// <summary>
        [JsonProperty("message_attachment_count")]
        [Description("MessageAttachmentCount")]
        public int? MessageAttachmentCount { get; set; }

        /// <summary>
        /// MessageMainAttachmentId
        /// Many2one
        /// ir.attachment
        /// <summary>
        [JsonProperty("message_main_attachment_id")]
        [Description("MessageMainAttachmentId")]
        public long? MessageMainAttachmentId { get; set; }

        /// <summary>
        /// WebsiteMessageIds
        /// One2many
        /// Website communication history
        /// mail.message
        /// res_id
        /// <summary>
        [JsonProperty("website_message_ids")]
        [Description("WebsiteMessageIds")]
        public long[] WebsiteMessageIds { get; set; }

        /// <summary>
        /// MessageHasSmsError
        /// Boolean
        /// If checked, some messages have a delivery error.
        /// <summary>
        [JsonProperty("message_has_sms_error")]
        [Description("MessageHasSmsError")]
        public bool? MessageHasSmsError { get; set; }

        /// <summary>
        /// Id
        /// Integer
        /// <summary>
        [JsonProperty("id")]
        [Description("Id")]
        public long Id { get; set; }

        /// <summary>
        /// DisplayName
        /// Char
        /// <summary>
        [JsonProperty("display_name")]
        [Description("DisplayName")]
        public string DisplayName { get; set; }

        /// <summary>
        /// CreateUid
        /// Many2one
        /// res.users
        /// <summary>
        [JsonProperty("create_uid")]
        [Description("CreateUid")]
        public long? CreateUid { get; set; }

        /// <summary>
        /// CreateDate
        /// Datetime
        /// <summary>
        [JsonProperty("create_date")]
        [Description("CreateDate")]
        public DateTime? CreateDate { get; set; }

        /// <summary>
        /// WriteUid
        /// Many2one
        /// res.users
        /// <summary>
        [JsonProperty("write_uid")]
        [Description("WriteUid")]
        public long? WriteUid { get; set; }

        /// <summary>
        /// WriteDate
        /// Datetime
        /// <summary>
        [JsonProperty("write_date")]
        [Description("WriteDate")]
        public DateTime? WriteDate { get; set; }

        /// <summary>
        /// LastUpdate
        /// Datetime
        /// <summary>
        [JsonProperty("__last_update")]
        [Description("LastUpdate")]
        public DateTime? LastUpdate { get; set; }
    }

}
